package net.maku.system.facade;

import net.maku.system.api.facade.SysRoleFacade;
import net.maku.system.dao.SysRoleDao;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class SysRoleFacadeImpl implements SysRoleFacade {

    private final SysRoleDao sysRoleDao;

    public SysRoleFacadeImpl(SysRoleDao sysRoleDao) {
        this.sysRoleDao = sysRoleDao;
    }

    @Override
    public List<String> geRoleCodeByUserId(Long id) {
        return sysRoleDao.geRoleCodeByUserId(id);
    }

    @Override
    public Integer getDataScopeByUserId(Long id) {
        return sysRoleDao.getDataScopeByUserId(id);
    }
}
